Skip to content

ci: PR-Agent moves to The-PR-Agent/pr-agent 0.49.0, with the GitHub extra it now needs - #1236

Merged
bong-water-water-bong merged 4 commits into
mainfrom
ci/pr-agent-the-pr-agent
Nov 6, 2026
Merged

bong-water-water-bong merged 4 commits into
mainfrom
ci/pr-agent-the-pr-agent

Conversation

@bong-water-water-bong

Copy link
Copy Markdown
Collaborator

qodo-ai/pr-agent is now The-PR-Agent/pr-agent (same repository, transferred; PyPI pr-agent points there; latest release v0.49.0, 2026-10-25). This moves our review job to it.

Changes

  • .github/workflows/pr-agent.yml: installs pr-agent[github]==0.49.0 into a per-version venv (~/pr-agent-venv-0.49.0) on the runner. The old command -v pr-agent check would have kept 0.43.0 forever after a bump.
  • The log check also fails on Failed to process the command and Failed to get git provider (PR-Agent exits 0 on both).
  • .pr_agent.toml: drops [openai] api_base/key. 0.49 ignores them in repo settings as host-only and logs a warning; the endpoint already comes from the workflow env (OPENAI__API_BASE, OPENAI__KEY), as the usage guide describes.

Measured on the strixhalo runner box (workflow env, local coder-llm on :8090, CONFIG__PUBLISH_OUTPUT=false, target PR #1224):

install result
pr-agent==0.49.0 Git provider 'github' could not be loaded because module 'github' is not installed → Failed to process the command, exit 0 (the old check passed it)
pr-agent[github]==0.49.0 review ran (6053 tokens, full diff), Review output is not published, no errors

This PR's own pr_agent run is the first live run of the new version.

🤖 Generated with Claude Code

bong-water-water-bong and others added 2 commits November 6, 2026 00:14
…xtra it now needs

qodo-ai/pr-agent is now github.com/The-PR-Agent/pr-agent (same repo, transferred; PyPI pr-agent points
there). The workflow installs 0.49.0 from it into a per-version venv on the runner, so the bump installs
fresh instead of the old `command -v pr-agent` check keeping 0.43.0 forever.

Measured on the strixhalo runner box before this change, with the workflow's own env and the local
coder-llm on :8090, publish_output off, on PR #1224:
- plain `pr-agent==0.49.0`: "Git provider 'github' could not be loaded because module 'github' is not
  installed" -> "Failed to process the command", and exit 0, which the old log check did not catch;
- `pr-agent[github]==0.49.0`: the review ran (6053 tokens, full diff) and ended "Review output is not
  published", no errors.

So the install uses the [github] extra, and the log check now also fails on "Failed to process the
command" and "Failed to get git provider". 0.49 ignores [openai] api_base/key in the repo's
.pr_agent.toml as host-only (it logs a warning); the endpoint already comes from the workflow env, so
those two keys are removed and the file says where the endpoint lives.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

PR Reviewer Guide 🔍

(Review updated until commit 11657ad)

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
🧪 No relevant tests
🔒 No security concerns identified
⚡ Recommended focus areas for review

Versioned Venv Usage

The workflow now uses a versioned virtual environment (~/pr-agent-venv-0.49.0) for PR-Agent installation, which is good for avoiding stale dependencies. However, the version is hardcoded in the workflow file, making it prone to drift if not updated alongside the PR-Agent version bump. This could lead to inconsistencies if the version in the workflow is not kept in sync with the actual version being used.

PRA_VERSION=0.49.0
venv="$HOME/pr-agent-venv-$PRA_VERSION"
export PATH="$venv/bin:$PATH"
if ! "$venv/bin/pr-agent" --help > /dev/null 2>&1; then
  python3 -m venv "$venv"
  "$venv/bin/pip" install -q "pr-agent[github]==$PRA_VERSION"
fi
Log Check Coverage

The updated log check now includes more error patterns, such as "Failed to get git provider", which is important for catching failures specific to the new GitHub provider requirement. However, the regex pattern might be too broad and could potentially mask other legitimate errors or warnings that are not related to the core functionality failure.

# PR-Agent exits 0 even when every model call failed or the command never ran, so check its log
run() {
  pr-agent --pr_url "$pr" "$@" 2>&1 | tee "$RUNNER_TEMP/pr-agent.log"
  if grep -qE "Failed to generate prediction|Error during LLM inference|Failed to (review|describe|generate|process the command)|Failed to get git provider" "$RUNNER_TEMP/pr-agent.log"; then
    echo "::error::PR-Agent failed (no model answer, or the command never ran): see the log above"; exit 1
  fi
Configuration Clarity

The comment explaining that [openai] api_base/key are ignored since PR-Agent 0.49 is helpful, but the configuration file itself no longer contains these settings. This change is correct, but it's important to ensure that all users or systems relying on this configuration file are aware of this change and that the new configuration is properly documented.

# own OpenAI-compatible server, no cloud API. The endpoint (OPENAI__API_BASE, OPENAI__KEY) is set in the
# workflow's env: since PR-Agent 0.49 an [openai] api_base/key in this file is ignored as host-only.

@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown

Persistent review updated to latest commit b2b5364

@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown

Persistent review updated to latest commit 11657ad

@bong-water-water-bong
bong-water-water-bong merged commit a083e31 into main Nov 6, 2026
9 checks passed
@bong-water-water-bong
bong-water-water-bong deleted the ci/pr-agent-the-pr-agent branch November 6, 2026 04:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant